import * as path from 'path'

import { ResolveOptions, AliasOptions } from 'vite'

const root = path.resolve(__dirname, '../../')

export const useResolve = (): ResolveOptions & { alias: AliasOptions } => {
  return {
    alias: {
      '@': path.resolve(root, './src'),
    },
  }
}
